{% extends "base.html" %}


{% block headtitle %}Trips Sign Up{% endblock %}
{% block pagetitle %}Trips Sign up{% endblock %}

{% block content %}

<h2>
  Step 2. Review your choices and fill out the form below.
</h2>

<table class="triplist">
  {% for trip in trips %}
  <tr class="{% if trip.trip_number|divisibleby:2 %}even{% else %}odd{% endif %}">
      <td>Trip #{{ trip.trip_number }}</td>
      <td>{{ trip.description }}</td>
      <td>{{ trip.start_date }}</td>
      <td>{{ trip.end_date }}</td>
      <td>{% if trip.is_member_only %}<b>member price</b>{% endif %}</td>
      <td>$ {{ trip.price|floatformat:2 }}</td>
  </tr>
  {% endfor %}
 
  {% if has_discount %}
  <tr>
      <td colspan="5" style="text-align: right">Discount:</td>
      <td>$ {{ discount|floatformat:2  }}</td>
  </tr>
  {% endif %}

  <tr>
      <td colspan="5" style="text-align: right"><b>Total:</b></td>
      <td><b>$ {{ total_cost|floatformat:2 }}</b></td>
  </tr>
</table>

<form action="" method="POST" class="signup">
<table class="form">
{{ form.as_table }}
</table>

<input type="submit" value="Continue">
<p>
Pressing "Continue" will confirm your sign up for the trip. Spots on the trip are not guaranteed until payment is received.
</p>
</form>

{% endblock %}
